package com.thjk.bdf.common.enmus;

/**
 * 
 * @author tao.pan
 * @Time：2019年4月22日 下午2:37:46
 * @version 1.0  
 * Function: 服务枚举
 */
public enum ServiceEnum {
	//成功
	SERVICE_SUCCESS("000000","SUCCESS"),
	SERVICE_FAIL("999999","系统异常"),
	
	SERVICE_PARAMETER_ERROR("000001","请求参数不能为空"),
	
	
	SERVICE_QUERY_NULL("000002","查询结果为空"),
	
	//客户经理手机号验证
	PHONE_CHECK_ERROR("000003","请输入正确的手机号码"),
	PHONE_CHECK_MISS("",""),
	PHONE_CHECK_NOAUTH("000004","没有该产品权限"),
	
	APPLY_INFO_MISSING("000005","没有申请记录"),
	
	SERVICE_000006("000006","参数校验失败"),
	
	//短信验证码
	SMS_NOT_EXIST("000001","校验码已经失效, 请重新获取校验码"),
	SMS_NOT_CORRECT("000002","校验码不正确, 请重新输入"),
	
	//支用状态
	LOAN_STATUS_1("1","审批中"),
	LOAN_STATUS_2("2","审批失败"),
	LOAN_STATUS_3("3","审批通过"),
	LOAN_STATUS_4("4","已放款"),
	LOAN_STATUS_5("5","已结清"),
	LOAN_STATUS_6("6","逾期"),
	LOAN_STATUS_7("7","审批作废"),
	LOAN_STATUS_8("8","贷款作废"),
	LOAN_STATUS_9("9","已签订"),
	LOAN_STATUS_10("10","放款失败"),
	LOAN_STATUS_21("21","审批通过（资金用途证明）"),
	
	
	
	//还款方式
	REPAY_METHOD_DEDX("DEDX","等额等息"),
	REPAY_METHOD_DBDX ("DBDX ","等本等息"),
	REPAY_METHOD_DBLJ("DBLJ","等比累进"),
	REPAY_METHOD_DEBX("DEBX","等额本息"),
	REPAY_METHOD_DEBJ("DEBJ","等额本金"),
	REPAY_METHOD_LSBQ("LSBQ","利随本清"),
	REPAY_METHOD_HDFX("HDFX"," 一次性还款付息"),
	REPAY_METHOD_AQHXDQHK("AQHXDQHK","按期还息到期还本"),
	REPAY_METHOD_DZHK("DZHK","定制还款"),
	REPAY_METHOD_DELJ("DELJ","等额累进"),
    
	
	//大数通知类型
	SCREENING_RESULT("SCREENING_RESULT","初筛通知"),
	SCORE_RESULT("SCORE_RESULT","评分通知"),
	APPROVAL_RESULT("APPROVAL_RESULT"," 审批结果通知"),
	CREDIT_INVALID_RESULT("CREDIT_INVALID_RESULT"," 征信失效通知 "),
	LIMIT_INVALID_RESULT("LIMIT_INVALID_RESULT"," 额度失效通知"),
	/**
	 * 启动备用资方
	 */
	ALTERNATE_FUNDS_KEY("ALTERNATE_FUNDS_KEY","启动备用资方"),
	/**
	 * 放款通知
	 */
	PUT_OUT_RESULT("PUT_OUT_RESULT","放款通知");

	private String code;
	private String desc;
	
	
	public String getCode() {
		return code;
	}


	public void setCode(String code) {
		this.code = code;
	}


	public String getDesc() {
		return desc;
	}


	public void setDesc(String desc) {
		this.desc = desc;
	}
	
	ServiceEnum(String code,String desc) {
		this.code = code;
		this.desc = desc;
	}
	
	public static String getRetValue(String value) {
		if (value != null) {
			for (ServiceEnum nameEnum : values()) {
				if (nameEnum.getCode().equals(value)) {
					return nameEnum.desc;
				}
			}
		}
		return null;
	}
}
